#ifndef _UTILS_CRC_H_
#define _UTILS_CRC_H_
#ifdef __cplusplus
extern "C"
{
#endif
    /**
     * @brief data crc16
     *
     * @param data
     * @param length
     * @return unsigned short
     */
    extern unsigned short utils_crc16(const char *data, int length);

    /**
     * @brief data crc32
     *
     * @param data
     * @param length
     * @return unsigned int
     */
    extern unsigned int utils_crc32(const char *data, int length);

    /**
     * @brief data crc32 fast
     *
     * @param data
     * @param length
     * @return unsigned int
     */
    extern unsigned int utils_crc32_fast(const unsigned char *data, int length);
#ifdef __cplusplus
}
#endif
#endif //_UTILS_CRC_H_